package ${package}


@RequestMapping("/${ifName}")
@Api(tags = "${swgget_api_name}")
@RestController
@Validated
public class ${controller_class_name} {


@Autowired
private ${service_class_name} service;

    @GetMapping("/")
    @ApiOperation("")
    public JsonData list(HttpServletRequest request, HttpServletResponse response) {

           List< ${po_class_name}> list = service.getList();
        return Callback.success(ResponseEnum.SUCCESS.getCode(), ResponseEnum.SUCCESS.getMemo(), list);

    }

    @PostMapping("/")
    @ApiOperation("")
    public JsonData opeartor(HttpServletRequest request, HttpServletResponse response
    , @ResponseBody ${po_class_name} po

    ) {


    service.opeartor(po);

    return Callback.success(ResponseEnum.SUCCESS.getCode(), ResponseEnum.SUCCESS.getMemo());

    }



    @DeleteMapping("/{id}")
    @ApiOperation("")
    public JsonData remove(HttpServletRequest request, HttpServletResponse response
    , @ApiParam(name = "id", value = "风格id", required = true) @PathVariable Integer id

    ) {

       service.remove(id);
    return Callback.success(ResponseEnum.SUCCESS.getCode(), ResponseEnum.SUCCESS.getMemo());

    }

}